home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 2009 February / PCWFEB09.iso / Software / Linux / Kubuntu 8.10 / kubuntu-8.10-desktop-i386.iso / casper / filesystem.squashfs / var / lib / dpkg / info / apmd.postrm < prev    next >
Text File  |  2008-06-19  |  687b  |  34 lines

  1. #!/bin/sh
  2. #
  3. # This is the postrm script for the Debian GNU/Linux apmd package
  4. #
  5. # Written by Dirk Eddelbuettel <edd@debian.org>   
  6.  
  7. set -e
  8.  
  9. del_link ()
  10. {
  11.     for FN in "${@}"; do
  12.     if [ -h "${FN}" ]; then
  13.         rm -f "${FN}" || true
  14.     fi
  15.     done
  16. }
  17.  
  18. case "$1" in
  19. (purge)
  20.     del_link /etc/apm/suspend.d/99hwclock /etc/apm/resume.d/00hwclock
  21.     [ -d /etc/apm/resume.d ] && rmdir -p --ignore-fail-on-non-empty /etc/apm/resume.d
  22.     [ -d /etc/apm/suspend.d ] && rmdir -p --ignore-fail-on-non-empty /etc/apm/suspend.d
  23.     ;;
  24. esac
  25.  
  26. # Automatically added by dh_installinit
  27. if [ "$1" = "purge" ] ; then
  28.     update-rc.d apmd remove >/dev/null || exit $?
  29. fi
  30. # End automatically added section
  31.  
  32.  
  33. exit 0
  34.